<template>
  <div class="pagination">
    <el-pagination
      @size-change="sizeChange"
      @current-change="currentChange"
      :current-page="options.currentPage"
      :page-sizes="[10, 15, 20, 30]"
      :page-size="options.pageSize"
      layout="total, sizes, prev, pager, next, jumper"
      :total="options.total"
      class="page"
    >
    </el-pagination>
  </div>
</template>

<script>
export default {
  name: "pagination",
  data() {
    return {};
  },
  props: {
    options: Object,
  },
  methods: {
    currentChange(val) {
      this.$emit("currentChange", val);
    },
    sizeChange(val) {
      console.log(val);
      this.$emit('sizeChange',val)
    },
  },
};
</script>

<style scoped lang="scss">
.pagination {
  width: 100%;
  height: 55px;
  text-align: left;
  .page {
    transform: translateY(calc(50% - 5px));
  }
}
</style>